import { createRouter, createWebHashHistory, createWebHistory } from 'vue-router'
import HomeView from '@/views/HomeView.vue'
import SearchView from '@/views/SearchView.vue'
import NotFind from '@/views/NotFind.vue'
const router = createRouter({
  history: createWebHistory(),
  routes: [
    { path: '/', redirect: '/home' },
    { path: '/home', component: () => import('@/views/HomeView.vue') },
    { path: '/search/:value?', component: () => import('@/views/SearchView.vue') },
    { path: '/:catchAll(.*)', component: () => import('@/views/NotFind.vue') }
  ]
})
export default router
